<div class="problemindexholder" problemindex="B">
 <div class="ttypography">
  <div class="problem-statement">
   <div class="header">
    <div class="title">
     B. Wrath
    </div>
    <div class="time-limit">
     <div class="property-title">
      time limit per test
     </div>
     2 seconds
    </div>
    <div class="memory-limit">
     <div class="property-title">
      memory limit per test
     </div>
     256 megabytes
    </div>
    <div class="input-file">
     <div class="property-title">
      input
     </div>
     standard input
    </div>
    <div class="output-file">
     <div class="property-title">
      output
     </div>
     standard output
    </div>
   </div>
   <div>
    <p>
     <span class="tex-font-style-it">
      Hands that shed innocent blood!
     </span>
    </p>
    <p>
     There are
     <span class="tex-span">
      <i>
       n
      </i>
     </span>
     guilty people in a line, the
     <span class="tex-span">
      <i>
       i
      </i>
     </span>
     -th of them holds a claw with length
     <span class="tex-span">
      <i>
       L
      </i>
      <sub class="lower-index">
       <i>
        i
       </i>
      </sub>
     </span>
     . The bell rings and every person kills some of people in front of him. All people kill others at the same time. Namely, the
     <span class="tex-span">
      <i>
       i
      </i>
     </span>
     -th person kills the
     <span class="tex-span">
      <i>
       j
      </i>
     </span>
     -th person if and only if
     <span class="tex-span">
      <i>
       j
      </i>
      &lt;
      <i>
       i
      </i>
     </span>
     and
     <span class="tex-span">
      <i>
       j
      </i>
      ≥
      <i>
       i
      </i>
      -
      <i>
       L
      </i>
      <sub class="lower-index">
       <i>
        i
       </i>
      </sub>
     </span>
     .
    </p>
    <p>
     You are given lengths of the claws. You need to find the total number of alive people after the bell rings.
    </p>
   </div>
   <div class="input-specification">
    <div class="section-title">
     Input
    </div>
    <p>
     The first line contains one integer
     <span class="tex-span">
      <i>
       n
      </i>
     </span>
     (
     <span class="tex-span">
      1 ≤
      <i>
       n
      </i>
      ≤ 10
      <sup class="upper-index">
       6
      </sup>
     </span>
     ) — the number of guilty people.
    </p>
    <p>
     Second line contains
     <span class="tex-span">
      <i>
       n
      </i>
     </span>
     space-separated integers
     <span class="tex-span">
      <i>
       L
      </i>
      <sub class="lower-index">
       1
      </sub>
      ,
      <i>
       L
      </i>
      <sub class="lower-index">
       2
      </sub>
      , ...,
      <i>
       L
      </i>
      <sub class="lower-index">
       <i>
        n
       </i>
      </sub>
     </span>
     (
     <span class="tex-span">
      0 ≤
      <i>
       L
      </i>
      <sub class="lower-index">
       <i>
        i
       </i>
      </sub>
      ≤ 10
      <sup class="upper-index">
       9
      </sup>
     </span>
     ), where
     <span class="tex-span">
      <i>
       L
      </i>
      <sub class="lower-index">
       <i>
        i
       </i>
      </sub>
     </span>
     is the length of the
     <span class="tex-span">
      <i>
       i
      </i>
     </span>
     -th person's claw.
    </p>
   </div>
   <div class="output-specification">
    <div class="section-title">
     Output
    </div>
    <p>
     Print one integer — the total number of alive people after the bell rings.
    </p>
   </div>
   <div class="sample-tests">
    <div class="section-title">
     Examples
    </div>
    <div class="sample-test">
     <div class="input">
      <div class="title">
       Input
      </div>
      <pre>4<br/>0 1 0 10<br/></pre>
     </div>
     <div class="output">
      <div class="title">
       Output
      </div>
      <pre>1<br/></pre>
     </div>
     <div class="input">
      <div class="title">
       Input
      </div>
      <pre>2<br/>0 0<br/></pre>
     </div>
     <div class="output">
      <div class="title">
       Output
      </div>
      <pre>2<br/></pre>
     </div>
     <div class="input">
      <div class="title">
       Input
      </div>
      <pre>10<br/>1 1 3 0 0 0 2 1 0 3<br/></pre>
     </div>
     <div class="output">
      <div class="title">
       Output
      </div>
      <pre>3<br/></pre>
     </div>
    </div>
   </div>
   <div class="note">
    <div class="section-title">
     Note
    </div>
    <p>
     In first sample the last person kills everyone in front of him.
    </p>
   </div>
  </div>
  <p>
  </p>
 </div>
</div>
